package com.xh.bussiness.textbook.model;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.extension.activerecord.Model;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

import java.io.Serializable;

/**
 * <p>
 * 讲义练习
 * </p>
 *
 * @author JQM
 * @since 2019-09-26
 */
@Data
@EqualsAndHashCode(callSuper = true)
@Accessors(chain = true)
@TableName("tb_textbook_practice")
public class TextbookPractice extends Model<TextbookPractice> {

    private static final long serialVersionUID = 1L;

    /**
     * 主键ID , 这里故意演示注解可以无
     */
    @TableId(value = "id",type = IdType.UUID)
    private String id;
    /**
     * 总分
     */
    private Integer totalScore;

    /**
     * 练习用时
     */
    private Long useTime;

    /**
     * 讲义id
     */
    private String textbookId;


    @Override
    protected Serializable pkVal() {
        return this.id;
    }
}
